package org.test;

import org.Entity.Student;

import java.lang.reflect.Constructor;

public class MainTest02 {
    public static void main(String[] args) throws Exception {
        Class<?> aClass = Class.forName("org.Entity.Student");
        Constructor<?> constructor = aClass.getConstructor(String.class, int.class, double.class);
        Student student = (Student) constructor.newInstance("张三", 18, 60.0);
        student.show();
    }
}
